130
Bioinformatics of the Brain
■Sobel Edge Detection
Sobel edge detector is proposed by Sobel [48] and used to reveal edge
regions in the image. It uses a 3x3 pair of convolution masks to calculate
the slope in both x-direction and y-direction. Convolution template of Sobel
detector is given in Equation 4.24 where Gx and Gy are used to calculate
gradient magnitude in the x-direction and y-direction, respectively.
Gx =
−1
0
1
−2
0
2
−1
0
1
Gy =
1
2
1
0
0
0
−1
−2
−1
(4.24)
Equation 4.25 represents the I(x, y) pixel and its neighboring pixels in the
image I [47].
I(x −1, y −1)
I(x, y −1)
I(x + 1, y −1)
I(x −1, y)
I(x, y)
I(x + 1, y)
I(x −1, y + 1)
I(x, y + 1)
I(x + 1, y + 1)
(4.25)
The calculation of the gradient value pair for the I(x, y) pixel on an I
image using the Sobel method is as follows [47]:
Gx
=
{I(x + 1, y −1) + 2I(x + 1, y) + I(x + 1, y + 1)}
(4.26)
−
{I(x −1, y −1) + 2I(x −1, y) + I(x −1, y + 1)}
Gy
=
{I(x −1, y −1) + 2I(x, y −1) + I(x + 1, y −1)}
(4.27)
−
{I(x −1, y + 1) + 2I(x, y + 1) + I(x + 1, y + 1)}
■Prewitt Edge Detection
Prewitt edge detection algorithm is introduced by Prewitt [49]. Prewitt
operator utilizes identical equations to those of the Sobel operator. However,
it does not give neighbors close to the center of the filter any extra weight.
Mask forms are expressed as in Equation 4.28.
Gx =
−1
0
1
−1
0
1
−1
0
1
Gy =
1
1
1
0
0
0
−1
−1
−1
(4.28)
The computation of the gradient value pair for the I(x, y) pixel on an I
image using the Prewitt method is as follows [47]:
Gx
=
{I(x + 1, y −1) + I(x + 1, y) + I(x + 1, y + 1)}
(4.29)
−
{I(x −1, y −1) + I(x −1, y) + I(x −1, y + 1)}
Gy
=
{I(x −1, y −1) + I(x, y −1) + I(x + 1, y −1)}
(4.30)
−
{I(x −1, y + 1) + I(x, y + 1) + I(x + 1, y + 1)}